<!DOCTYPE HTML>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<meta charset="utf-8">
<head th:include="include :: header"></head>
<body class="gray-bg">
    <div class="container-div">
		<div class="col-sm-12 select-info">
				<form id="post-form">
					<div class="select-list">
						<ul>
							<li class="select-time">
								<label>时间： </label>
								<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginTime]"/>
								<span>-</span>
								<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endTime]"/>
							</li>
							<li>
								职工姓名：<input type="text" name="userName"/>
							</li>
							<li>
								<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
								<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
							    <a class="btn btn-success btn-rounded btn-sm" onclick="$.table.exportExcel()" shiro:hasPermission="system:post:export"><i class="fa fa-download"></i>&nbsp;导出</a>
							</li>
						</ul>
					</div>
				</form>
			</div>
		<div class="col-sm-12 select-table table-striped">
			<table id="bootstrap-table" data-mobile-responsive="true"></table>
		</div>
    </div>
    <div th:include="include :: footer"></div>
    <script th:inline="javascript">
        var editFlag = [[${@permission.hasPermi('statistic:mealCount:edit')}]];
        var removeFlag = [[${@permission.hasPermi('statistic:mealCount:remove')}]];
        var prefix = ctx + "statistic/mealCount"

        $(function() {
            var options = {
                url: prefix + "/list",
                createUrl: prefix + "/add",
                updateUrl: prefix + "/edit/{id}",
                removeUrl: prefix + "/remove",
                exportUrl: prefix + "/exportMealCount",
                search: false,
		        showExport: false,
                modalName: "人员报餐统计",
                columns: [{
					field : 'userName', 
					title : '姓名' 
				},
				{
					field : 'brkCount', 
					title : '早餐/份' 
				},
				{
					field : 'brkCountNot', 
					title : '早餐未吃/份' 
				},
				{
					field : 'brkCountGuest', 
					title : '早餐客餐/份' 
				},
				{
					field : 'lchCount', 
					title : '午餐/份' 
				},
				{
					field : 'lchCountNot', 
					title : '午餐未吃/份' 
				},
				{
					field : 'lchCountGuest', 
					title : '午餐客餐/份' 
				},
				{
					field : 'dnerCount', 
					title : '晚餐/份' 
				},
				{
					field : 'dnerCountNot', 
					title : '晚餐未吃/份' 
				},{
					field : 'dnerCountGuest', 
					title : '晚餐客餐/份' 
				},{
					field : 'otherCount',
					title : '其他餐/份'
				},
				{
					field : 'otherCountNot',
					title : '其他未吃/份'
				},{
					field : 'otherCountGuest',
					title : '其他客餐/份'
				}]
            };
            $.table.init(options);
        });
    </script>
</body>
</html>